package com.ruoyi.bussiness.service.impl;

import java.util.List;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import com.ruoyi.bussiness.mapper.TraClassroomMapper;
import com.ruoyi.bussiness.domain.TraClassroom;
import com.ruoyi.bussiness.service.ITraClassroomService;
import com.ruoyi.common.core.text.Convert;

/**
 * 培训教室Service业务层处理
 * 
 * @author ruoyi
 * @date 2023-11-12
 */
@Service
public class TraClassroomServiceImpl implements ITraClassroomService 
{
    @Autowired
    private TraClassroomMapper traClassroomMapper;

    /**
     * 查询培训教室
     * 
     * @param id 培训教室主键
     * @return 培训教室
     */
    @Override
    public TraClassroom selectTraClassroomById(Long id)
    {
        return traClassroomMapper.selectTraClassroomById(id);
    }

    /**
     * 查询培训教室列表
     * 
     * @param traClassroom 培训教室
     * @return 培训教室
     */
    @Override
    public List<TraClassroom> selectTraClassroomList(TraClassroom traClassroom)
    {
        return traClassroomMapper.selectTraClassroomList(traClassroom);
    }

    /**
     * 新增培训教室
     * 
     * @param traClassroom 培训教室
     * @return 结果
     */
    @Override
    public int insertTraClassroom(TraClassroom traClassroom)
    {
        return traClassroomMapper.insertTraClassroom(traClassroom);
    }

    /**
     * 修改培训教室
     * 
     * @param traClassroom 培训教室
     * @return 结果
     */
    @Override
    public int updateTraClassroom(TraClassroom traClassroom)
    {
        return traClassroomMapper.updateTraClassroom(traClassroom);
    }

    /**
     * 批量删除培训教室
     * 
     * @param ids 需要删除的培训教室主键
     * @return 结果
     */
    @Override
    public int deleteTraClassroomByIds(String ids)
    {
        return traClassroomMapper.deleteTraClassroomByIds(Convert.toStrArray(ids));
    }

    /**
     * 删除培训教室信息
     * 
     * @param id 培训教室主键
     * @return 结果
     */
    @Override
    public int deleteTraClassroomById(Long id)
    {
        return traClassroomMapper.deleteTraClassroomById(id);
    }
}
